package com.zunipe.render;

import com.zunipe.records.BasicColor;
import com.zunipe.records.BlockPosWithColor;
import net.minecraft.block.Block;
import net.minecraft.block.Blocks;

import java.util.HashMap;
import java.util.HashSet;
import java.util.Map;
import java.util.Set;

public class RenderBlockList
{
    private static Set<BlockPosWithColor> renderQueue = new HashSet<>();
    public static final Map<Block, BasicColor> blockWithColor = new HashMap<>();

    public static void init()
    {
        blockWithColor.put(Blocks.EMERALD_ORE, new BasicColor(0, 255, 0));
        blockWithColor.put(Blocks.DEEPSLATE_EMERALD_ORE, new BasicColor(0, 168, 0));
        blockWithColor.put(Blocks.DIAMOND_ORE, new BasicColor(0, 255, 255));
        blockWithColor.put(Blocks.DEEPSLATE_DIAMOND_ORE, new BasicColor(0, 196, 220));
        blockWithColor.put(Blocks.GOLD_ORE, new BasicColor(255, 255, 0));
        blockWithColor.put(Blocks.DEEPSLATE_GOLD_ORE, new BasicColor(255, 215, 0));
        blockWithColor.put(Blocks.LAPIS_ORE, new BasicColor(0, 0, 255));
        blockWithColor.put(Blocks.DEEPSLATE_LAPIS_ORE, new BasicColor(0, 0, 120));
        blockWithColor.put(Blocks.COPPER_ORE, new BasicColor(255, 127, 36));
        blockWithColor.put(Blocks.DEEPSLATE_COPPER_ORE, new BasicColor(205, 102, 29));
        blockWithColor.put(Blocks.IRON_ORE, new BasicColor(255, 255, 240));
        blockWithColor.put(Blocks.DEEPSLATE_IRON_ORE, new BasicColor(255, 248, 220));
        blockWithColor.put(Blocks.REDSTONE_ORE, new BasicColor(255, 0, 0));
        blockWithColor.put(Blocks.DEEPSLATE_REDSTONE_ORE, new BasicColor(205, 0, 0));
    }

    public static void setList(Set<BlockPosWithColor> set)
    {
        renderQueue = set;
    }

    public static Set<BlockPosWithColor> getList()
    {
        return renderQueue;
    }
}
